#include <stdio.h>
#include <string.h>
int main()
{
    int i;
    char a[5]={'w','a','z','g','\0'};

    printf("正序字符串为:\n");
    for ( i = 0; i < 5; i++)
    {
        printf("%c\n",a[i]);
    }
     
    printf("逆序字符串为:\n");
    for ( i = 0; i < 5; i++)
    {
        printf("%c\n",a[4-i]);
    }

    printf("该字符串的长度是%d",strlen(a));

    return 0;
}